import 'package:json_annotation/json_annotation.dart';

part 'voice_ans.g.dart';

@JsonSerializable()
class VoiceAns {
  @JsonKey(defaultValue: '')
  final String playUrl;
  @JsonKey(defaultValue: '')
  final String uuid;
  @JsonKey(defaultValue: 0)
  final double duration;

  VoiceAns({
    required this.playUrl,
    required this.uuid,
    required this.duration,
  });

  factory VoiceAns.fromJson(Map<String, dynamic> json) =>
      _$VoiceAnsFromJson(json);

  Map<String, dynamic> toJson() => _$VoiceAnsToJson(this);
}
